<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>w3school导航条</title>
    <style>

        body{
            background-color: #bfa;
        }

        *{
            padding: 0;
            margin: 0;
        }

        ul{
            width: 1137px;
            height: 48px;
            margin: 50px auto;
            background-color: rgb(232,231,227);
            
        }

        li{
            list-style: none;
            
        }

        li:last-child a{
            /* 给单独的 li 设置内边距 */
            padding: 0 50px 0 50px;
        }

        a{  
            /* 将 a 行内元素变成块元素 */
            display: block;
            line-height: 48px;
            float: left;
            /* 去除超链接的下划线 */
            text-decoration: none;
            color: #888887;
            padding: 0 44px;
            font-size: 14px;
        }

        
        a:hover{
            color:#E7E6E2;
            background-color: rgb(63,63,63);
        }

    </style>

</head>
<body>
    <ul>
        <li>
            <a href="#">HTML/CSS</a>
        </li>
        <li>
            <a href="#">Brouser Side</a>
        </li>
        <li>
            <a href="#">Server Side</a>
        </li>
        <li>
            <a href="#">Programming</a>
        </li>
        <li>
            <a href="#">XML</a>
        </li>
        <li>
            <a href="#">Web Building</a>
        </li>
        <li>
            <a href="#">Reference</a>
        </li>
    </ul>
</body>
</html>